home *** CD-ROM | disk | FTP | other *** search
/ Gold Medal Software 3 / Gold Medal Software - Volume 3 (Gold Medal) (1994).iso / music / 5mods_1.arj / SMURF02.MOD < prev    next >
Text File  |  1994-01-09  |  8KB  |  194 lines

  1. Papa Smurf #1 @29969
  2. Sat Jan 08 11:17:03 1994
  3. 0R: net34: @2050 (via @1040) [15:40 01/08/94]
  4. 0R: net33: @1040 (via @1050) [16:02 01/08/94]
  5. 0R: net33: @19995 (via @29969) [11:14 01/08/94]
  6. 0R: net33: @29969 [11:17 01/08/94]
  7. ┌────────────────────────────────────────────────────────────────────────────┐
  8. │ Mod Name      : SMURF02.MOD      Mod Author: PAPA SMURF   1@29969 WWIVnet  │
  9. │ Difficulty    : █▒▒▒▒▒▒▒▒▒                                1@2000  FIITAnet │
  10. │ WWIV Version  : 4.23                                                       │
  11. │ Mod Date      : 1/8/93                                                     │
  12. │ Files Affected: LILO.C NEWUSER.C FCNS.H                                    │
  13. │ Description   : Ask user if they would like adult access, age permitting.  │
  14. │                 Send SSM to Sysop of new user ADULT status/request.        │
  15. └────────────────────────────────────────────────────────────────────────────┘
  16.  
  17. ┌─────────────────────────┐
  18. │ ==   Existing Code      │
  19. │ =+   Change Code        │
  20. │ ++   Add This Code      │
  21. │ --   Delete This Code   │
  22. └─────────────────────────┘
  23.  
  24. ══[ Long Description ]════════════════════════════════════════════════════════
  25.  
  26.   This is a total rewrite of FOXX02.mod and SMURF01.mod.  IF you have either
  27. of these two installed, please delete them and use only this one if you like
  28. the changes.  (Make sure to *delete* the call to input_adult() in NEWUSER.C
  29. as it will be called only from LILO.C) There is a *FIX* in here for
  30. SMURF01.mod where I mis-spelled something.  The old SMURF01.mod gave a -1 for
  31. user number sometimes and that is fixed now.
  32. Watch for lines that say //WRAPPED
  33. You must unwrap them.
  34.  
  35.   I wrote this mod because my board is mostly an adult board.  If the user is
  36. over the age of 17 it ask if they would like adult access on your system, if
  37. they answer yes it then prints the terms of adult access and ask the user to
  38. agree to the terms, then writes reply to thisuser.note.
  39.  
  40. ══[   The Mod   ]═════════════════════════════════════════════════════════════
  41.  
  42. Step 1: Back-up the source ;)
  43.  
  44. Step 2: Load up FCNS.H
  45.  
  46. <* Add the following to the FCNS.H file before void input_dataphone(void) *>
  47. <* if you do not have FOXX02.MOD installed else skip this step            *>
  48.  
  49. == /* File: newuser.c */
  50. ++ void input_adult(void);
  51.  
  52. Save and Close FCNS.H.....................
  53.  
  54. Step 3: Load up NEWUSER.C
  55.  
  56. <* Delete the following after input_screensize(); if you have FOXX02.mod *>
  57. <* installed already if not then skip this step.                         *>
  58.  
  59. == input_age(&thisuser);
  60. == input_comptype();
  61. == input_screensize();
  62. -- input_adult(void);
  63.  
  64.  
  65. Step 4: Load up NEWUSER.C
  66.  
  67. <* ++Add (block copy) the following to the end of the NEWUSER.C file *>
  68. <* delete the old input_adult(void) if you have it and replace it.   *>
  69.  
  70. void input_adult(void)
  71. {
  72.   char s1[7],s2[81];
  73.  
  74.   if (thisuser.age>17) {
  75.     nl();
  76.     npr("5Would you like adult access? ");0
  77.     if (yn()) {
  78.       outchr(12);
  79.       if (okansi) {
  80.                    nl();
  81.                    pl("    6WARNING1!! 6WARNING1!! 6WARNING1!! 6WARNING1!! 6WA0
  82.                        RNING1!! 6WARNING1!! 6WARNING1!!");  //WRAPPED0
  83.                    printfile("ADULT.ANS");
  84.                    } else {
  85.                            pl("    WARNING!! WARNING!! WARNING!! WARNING!!
  86.                            WARNING!! WARNING!! WARNING!!");  //WRAPPED
  87.                            printfile("ADULT.MSG");
  88.                            }
  89.                    nl();
  90.                    npr("5Type 2I AGREE 5to accept these terms.1: ");0
  91.                    mpl(7);
  92.                    input(s1,7);
  93.                    if (!strcmp(s1,"I AGREE")) {
  94.                         strcpy(thisuser.note,"AGREED TO ADULT TERMS");
  95.                         sprintf(s2,"%s %s & Wants Adult Access. Age:
  96. %d",nam(&thisuser, usernum),thisuser.note,thisuser.age);  //WRAPPED
  97.                          ssm(1,0,s2);
  98.                          nl();
  99.                          return;
  100.                    } else {
  101.                    strcpy(thisuser.note,"DID NOT AGREE TO ADULT TERMS");
  102.                    pl("5If you made a mistake or would like to request adult");0
  103.                    npr("5access at another time1, 5email 2%s1.\r\n",syscfg.0
  104.                         sysopname);  //WRAPPED
  105.           sprintf(s2,"%s %s & Dosn't want Adult Access. Age: %d",nam(&thisuser
  106.           ,usernum),thisuser.note,thisuser.age);  //WRAPPED
  107.           ssm(1,0,s2);
  108.           nl();
  109.           return;
  110.          }
  111.     }
  112.     strcpy(thisuser.note,"DID NOT AGREE TO ADULT TERMS");
  113.     pl("5If you made a mistake or would like to request adult");0
  114.     npr("5access at another time1, 5email 2%s1.\r\n",syscfg.0sysopname);
  115.     sprintf(s2,"%s %s & Dosn't want Adult Access. Age: %d",nam(&thisuser
  116.     ,usernum),thisuser.note,thisuser.age); //WRAPPED
  117.     ssm(1,0,s2);
  118.     nl();
  119.     return;
  120.    }
  121.     strcpy(thisuser.note,"MINOR - NO ADULT ACCESS");
  122.     sprintf(s2,"%s is a %s.  Age: %d",nam(&thisuser,usernum),thisuser.note,
  123.     thisuser.age);  //WRAPPED
  124.     ssm(1,0,s2);
  125.     nl();
  126. }
  127.  
  128. Save and Close NEWUSER.C....................
  129.  
  130.  
  131. Step 5: Load up LILO.C
  132.  
  133. <* Search for the following in the LILO.C file *>
  134.  
  135. == void logon(void)
  136. == {
  137.  
  138.  
  139. <* Then add the s3 variable *>
  140.  
  141. =+  char s[255],s1[181],s2[81],s3[60],*ss; // add s3[60] for SMURF02.MOD
  142.  
  143.  
  144. <* A little further down Search for the following *>
  145.  
  146. ==    if (thisuser.waiting) {
  147. ==      prt(5,get_string(377));
  148. ==      if (yn())
  149. == readmail();
  150. ==    }
  151.  
  152. <* Then ++ADD (block copy) the following after that closed bracket *>
  153. <* Delete the old code for SMURF01.mod if you have it and replace  *>
  154.  
  155. /*************************************************************************/
  156. // Determine if the users NOTE is equal to either of the three catagories
  157. // and if not then validate them for the adult section.  This will validate
  158. // all users for ADULT ACCESS. This updates old records so that you the
  159. // Sysop can prove that all Adult Access users have agreed with your
  160. // requirements. Remember that if you install this mod, input_adult() will
  161. // rewrite the old users note with Adult status..... *(New SMURF01.mod)*
  162.  
  163.     strcpy(s3,thisuser.note);
  164.  
  165.     if((!strcmp(s3,"AGREED TO ADULT TERMS")) || (!strcmp(s3,"DID NOT AGREE
  166.     TO ADULT TERMS")) || (!strcmp(s3,"MINOR - NO ADULT ACCESS"))) { //WRAPPED
  167.        nl();
  168.        npr("5Your Adult Status is: 2%s1.\r\n",s3);0
  169.        } else {
  170.                nl();
  171.                prt(4,"You are now being validated for the Adult Section.");
  172.                nl();
  173.                pausescr();
  174.                if(thisuser.age<18) {
  175.                   prt(4,"Sorry, had to update the records and you did not
  176.                   qualify.");  //WRAPPED
  177.                   nl();
  178.                   input_adult();
  179.                   } else {
  180.                           nl();
  181.                           input_adult();
  182.                          }
  183.                }
  184.  Save and Close LILO.C.....................
  185.  
  186. Step 6: Exit Editor and TYPE MAKE and because FCNS.H was modified, it will
  187. have to recompile the whole BBS :( so go get someting to snack on.
  188. ══[ Disclaimer ]══════════════════════════════════════════════════════════════
  189. Not responsible for HD crashes or anything else...
  190.  
  191. Full Credit goes to FOXX 1@4907 WWIVnet for origional writting input_adult()
  192. All other Credit goes to Papa Smurf 1@29969 WWIVnet for putting it all
  193. togeather.
  194.